home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PsL Monthly 1993 December
/
PSL Monthly Shareware CD-ROM (December 1993).iso
/
prgmming
/
dos
/
pascal
/
keymakr.exe
/
lha
/
TESTAD.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1990-10-02
|
2KB
|
86 lines
program testad;
uses AddrKey, crt, readttt5, fastttt5, iottt5;
{ If you do not have the TTT toolbox remove readttt5, fasttt5, iottt5
from the USES statement.}
var
addr : AddrType;
key : String;
ans : Boolean;
begin
{$V-}
addr.addr1:='';
addr.addr2:='';
addr.city:='';
addr.state:='';
addr.zip:='';
Clrscr;
{ NON-TTT - remove from here to }
Create_Fields(5);
Set_Default_Rules(AllowNull+JumpIfFull);
Add_Field(1,5,2,5,2,20,5);
Add_Field(2,1,3,1,3,20,6);
Add_Field(3,2,4,2,4,20,7);
Add_Field(4,3,5,3,5,41,7);
Add_Field(5,4,1,4,1,50,7);
String_Field(1,Addr.Addr1,'***************************************');
String_Field(2,Addr.Addr2,'***************************************');
String_Field(3,Addr.city,'***************');
String_Field(4,Addr.State,'**');
String_Field(5,Addr.Zip,'#####');
{here}
Repeat
Clrscr;
{non-ttt - remove from here to...}
WriteAt(11,5,White,Black,'Address:');
WriteAt(14,7,White,Black,'City:');
WriteAt(37,7,White,Black,'St:');
WriteAt(45,7,White,Black,'Zip:');
Display_All_Fields;
Process_Input(1);
{here}
{non-ttt replace previous code with
GotoXY(11,5); Write('address:');
GotoXY(14,7); write('City:');
GotoXY(37,7); Write('St:');
GotoXY(45,7); Write('Zip:');
GotoXY(20,5); readln(addr.addr1);
GotoXY(20,6); readln(addr.addr2);
GotoXY(20,7); readln(addr.City);
GotoXY(41,7); readln(addr.St);
GotoXY(50,7); readln(addr.Zip);
this}
key := AddrToKeyT(addr);
GotoXY(12,13); Writeln('zipcode - ',AKKey.ZIP);
GotoXY(12,14); Writeln('Street - ',akkey.street);
GotoXY(12,15); Writeln('Street# - ',akkey.StNum);
GotoXY(12,16); Writeln('Apt - ',akkey.Apt);
{NON-TTT - remove from here }
Read_YN(25,22,'Again? ',1,ans)
{to here}
{non-ttt replace previous code with
while(ans <> 'Y' or ans <> 'N') do
begin
ans := 'Y'
GotoXY(25,22) Write('Again? Y');
GotoXY(25,29) Readln(ans);
UpCase(ans);
end;
this}
Until(not ans);
Clrscr;
end.